package com.xomily.devops.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xomily.common.annotation.Excel;
import com.xomily.common.core.domain.BaseEntity;

/**
 * CPU监测日志对象 dev_cpu_log
 * 
 * @author xomily
 * @date 2021-11-29
 */
public class DevCpuLog extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    private Long id;

    /** 主机id */
    @Excel(name = "主机id")
    private Long hostId;
    
    /** 主机IP地址 */
    @Excel(name = "主机IP地址")
    private String ip;

    /** USER */
    @Excel(name = "USER")
    private String user;

    /** STEAL */
    @Excel(name = "STEAL")
    private Long steal;

    /** SYS指标 */
    @Excel(name = "SYS指标")
    private BigDecimal sys;

    /** NICE */
    @Excel(name = "NICE")
    private Long nice;

    /** IDLE */
    @Excel(name = "IDLE")
    private BigDecimal idle;

    /** IOWAIT */
    @Excel(name = "IOWAIT")
    private BigDecimal iowait;

    /** IRQ */
    @Excel(name = "IRQ")
    private String irq;

    /** SOFT */
    @Excel(name = "SOFT")
    private String soft;

    
    /** 使用率 */
    @Excel(name = "使用率")
    private double useRate;
  
    /** 风扇 */
    @Excel(name = "风扇")
    private String fan;

    /** 温度 */
    @Excel(name = "温度")
    private double temperature;

    /** 发生时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "发生时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date generateTime;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setHostId(Long hostId) 
    {
        this.hostId = hostId;
    }

    public Long getHostId() 
    {
        return hostId;
    }
    
    public void setIp(String ip) 
    {
        this.ip = ip;
    }

    public String getIp() 
    {
        return ip;
    }
    public void setUser(String user) 
    {
        this.user = user;
    }

    public String getUser() 
    {
        return user;
    }
    public void setSteal(Long steal) 
    {
        this.steal = steal;
    }

    public Long getSteal() 
    {
        return steal;
    }
    public void setSys(BigDecimal sys) 
    {
        this.sys = sys;
    }

    public BigDecimal getSys() 
    {
        return sys;
    }
    public void setNice(Long nice) 
    {
        this.nice = nice;
    }

    public Long getNice() 
    {
        return nice;
    }
    public void setIdle(BigDecimal idle) 
    {
        this.idle = idle;
    }

    public BigDecimal getIdle() 
    {
        return idle;
    }
    public void setIowait(BigDecimal iowait) 
    {
        this.iowait = iowait;
    }

    public BigDecimal getIowait() 
    {
        return iowait;
    }
    public void setIrq(String irq) 
    {
        this.irq = irq;
    }

    public String getIrq() 
    {
        return irq;
    }
    public void setSoft(String soft) 
    {
        this.soft = soft;
    }

    public String getSoft() 
    {
        return soft;
    }
    public void setUseRate(double useRate) 
    {
        this.useRate = useRate;
    }

    public double getUseRate() 
    {
        return useRate;
    }
    public void setFan(String fan) 
    {
        this.fan = fan;
    }

    public String getFan() 
    {
        return fan;
    }
    
    public void setTemperature(double temperature) 
    {
        this.temperature = temperature;
    }

    public double getTemperature() 
    {
        return temperature;
    }
    public void setGenerateTime(Date generateTime) 
    {
        this.generateTime = generateTime;
    }

    public Date getGenerateTime() 
    {
        return generateTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("ip", getIp())
            .append("user", getUser())
            .append("steal", getSteal())
            .append("sys", getSys())
            .append("nice", getNice())
            .append("idle", getIdle())
            .append("iowait", getIowait())
            .append("irq", getIrq())
            .append("soft", getSoft())
            .append("fan", getFan())            
            .append("temperature", getTemperature())
            .append("createTime", getCreateTime())
            .append("generateTime", getGenerateTime())
            .toString();
    }
}
